home *** CD-ROM | disk | FTP | other *** search
/ MacFormat 1999 Spring / macformat-077.iso / Shareware Plus / Development / SpriteWorld 2.2 / SpriteWorld files / Utils / SWApplication.h < prev    next >
Encoding:
Text File  |  1998-08-07  |  1.8 KB  |  60 lines  |  [TEXT/CWIE]

  1. ///--------------------------------------------------------------------------------------
  2. //    SWApplication.h
  3. //
  4. //    Created:    Sunday, April 11, 1993
  5. //    By:        Tony Myles. Extensive modifications by Vern Jensen and Karl Bunker.
  6. //
  7. //    Copyright: © 1993 Tony Myles, All rights reserved worldwide.
  8. ///--------------------------------------------------------------------------------------
  9.  
  10.  
  11. #ifndef __SWAPPLICATION__
  12. #define __SWAPPLICATION__
  13.  
  14.  
  15. #define kNumberOfMoreMastersCalls        3
  16. #define kWindowResID                    128
  17.  
  18. #define kErrorAlertResID                128
  19. #define kCantRunAlertResID                129
  20.  
  21. #define kErrorStringListResID            128
  22. #define kFatalErrorStringIndex            1
  23. #define kCantFindResourceStringIndex    2
  24. #define kOutOfMemoryStringIndex            3
  25. #define kResNotFoundStringIndex            4
  26.  
  27. #define kSeriousDamageString "\pAn error has occurred, and the error string couldn't even be found!"
  28.  
  29. ///--------------------------------------------------------------------------------------
  30. // Macros for ReportIfError and CantFindResource
  31. ///--------------------------------------------------------------------------------------
  32.  
  33. #define FatalError(err)            if (err) ReportError(err, __FILE__, __LINE__);
  34. #define CantFindResource()        DoCantFindResource(__FILE__, __LINE__);
  35.  
  36.  
  37. ///--------------------------------------------------------------------------------------
  38. // Function prototypes
  39. ///--------------------------------------------------------------------------------------
  40.  
  41.  
  42. #ifdef __cplusplus
  43. extern "C" {
  44. #endif
  45.  
  46.  
  47. void    Initialize(short numberOfMasters);
  48. void    SetCleanUpSpriteWorld(SpriteWorldPtr spriteWorldP);
  49. void    ReportError(OSErr err, char* filename, int lineNumber);
  50. void    DoCantFindResource(char* filename, int lineNumber);
  51. void    ErrorAlert(OSErr err, char* filename, int lineNumber, short errorStringIndex);
  52. void    CantRunOnThisMachine( void );
  53.  
  54.  
  55. #ifdef __cplusplus
  56. }
  57. #endif
  58.  
  59.  
  60. #endif /* __SWAPPLICATION__ */